package com.briup.web.controller;

import com.briup.service.IOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;


@Controller
public class OrderSureController {
    @Autowired
    private IOrderService orderService;
    @GetMapping(value = {"/paySuccess"})
    public String paySuccess(Model model,String out_trade_no) {
        //付款成功， 修改订单状态
        //将订单状态设置为以支付
        System.out.println(out_trade_no);
        orderService.paySuccess(out_trade_no);
        model.addAttribute("orderId",out_trade_no);
        return "orderSure";
    }
}
